﻿using CozeDomain.Entities;
using CozeDto.ProjectDtos;
using CozeDto.ProjectInstanceDtos;
using D.UtilCore.Dtos;
using D.UtilFreesqlOrm;

namespace CozeDomain.IServices
{
    /// <summary>
    /// 站点所属项目接口
    /// </summary>
    public interface IProjectInstanceService : IBaseService<ProjectInstanceEntity>
    {
        /// <summary>
        /// 添加
        /// </summary>
        /// <param name="reqAddProjectInstance"></param>
        /// <returns></returns>
        Task<ApiResult<int>> AddProjectInstanceAsync(ReqAddProjectInstance reqAddProjectInstance);

        /// <summary>
        /// 获取列表
        /// </summary>
        /// <param name="tenantId"></param>
        /// <returns></returns>
        Task<ApiResult<RepProjectList>> QueryProjectListByTenantIdAsync(string tenantId);

        /// <summary>
        /// 获取列表
        /// </summary>
        /// <param name="reqQueryProjectInstanceList"></param>
        /// <returns></returns>
        Task<ApiResult<List<RepProjectInfo>>> QueryProjectListAsync(ReqQueryProjectInstanceList reqQueryProjectInstanceList, string userId);

        /// <summary>
        /// 获取单个
        /// </summary>
        /// <param name="id"></param>
        /// <param name="userId"></param>
        /// <returns></returns>
        Task<ApiResult<RepProjectInfo>> GetProjectAsync(string id, string userId);
        
        /// <summary>
        /// 分页查询
        /// </summary>
        /// <param name="reqQueryProjectInstancePage"></param>
        /// <returns></returns>
        Task<ApiResult<PageModel<RepProjectInstanceInfo>>> QueryProjectInstancePagesAsync(ReqQueryProjectInstancePage reqQueryProjectInstancePage);
    }
}
